package com.jk.dmconsumer.controller;

import com.jk.dmcommon.wlentity.GoodsDetailEntity;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.servlet.ModelAndView;

/**
 * 文件名称:JumpController
 *
 * @Description //TODO
 * @Date 2021/9/10 6:47
 * 作者 王乐
 * Copyright (c) 2021,  All Rights Reserved.</pre>
 */
@Controller
public class JumpController {
    //跳转搜索页面，传类型和城市id
    @RequestMapping("/homeJump/toSearch")
    public ModelAndView toSearch(GoodsDetailEntity goods,Model model){
        model.addAttribute("goodsToSearch",goods);
        ModelAndView mv =  new ModelAndView("zhanshiqiantai/search.damai.cn/ceshi");
        return mv;
    }
    /**
    *  @方法描述 (退出登录，返回首页)
     * @Author 王乐
     * @Description //TODO 
     * @Date  2021/9/14 1:49
     * @Param []
     * @return java.lang.String
     **/
    public String logout() {
        return "home";
    }

    //跳转支付页面,传座位信息
    @RequestMapping("/homeJump/toPay")
    public ModelAndView toPay(String site,Model model){
        model.addAttribute("site",site);
        ModelAndView mv =  new ModelAndView("paymentOrder");
        return mv;
    }






}
